package cn.fj.hrm.basic.util;

import lombok.Data;

@Data
public class JsonResult {

    private Boolean success = true;
    private String msg = "操作成功";
    private Object data;

    /**
     * 返回本身对象
     * @return
     */
    public static JsonResult me(){
        return new JsonResult();
    }

    public JsonResult setSuccess(Boolean success) {
        this.success = success;
        return this;
    }

    public JsonResult setMsg(String msg) {
        this.msg = msg;
        return this;
    }
    public JsonResult setData(Object data){
        this.data = data;
        return this;
    }
}
